#include <iostream>
#include <sstream>

template<typename ...Args>
void print(const Args&...args){
    std::stringstream ss;
    ((ss<<args),...);
    std::cout<<ss.str();
}

template<typename T>
class Range{
private:
T _start,_end,_step;
public:
    constexpr Range()=delete;
    constexpr Range(const T start,const T end,const T step)noexcept:_start(start),_end(end),_step(step){}
    constexpr Range(const T start,const T end)noexcept:Range(start,end,1){}
    constexpr Range(const T end)noexcept:Range(1,end,1){}

    struct Iterator{
        T current,step;
        constexpr Iterator()=delete;
        constexpr Iterator(const T start,const T step)noexcept:current(start),step(step){}
        constexpr bool operator!=(const Iterator &other)const noexcept{
            return current<other.current;
        }
        constexpr Iterator& operator++()noexcept{
            current+=step;
            return *this;
        }
        constexpr T operator*()const noexcept{
            return current;
        }
    };

    constexpr Iterator begin(){
        return Iterator(_start,_step);
    }
    constexpr Iterator end(){
        return Iterator(_end,_step);
    }
};


int main(const int argc,const char* argv[]){
    for(auto i:Range(1,11,2)){
        for(auto j:Range(1,11,2)){
            print("[","i: ",i," ,j: ",j,"] ");
        }
        print("\n");
    }
    print("\n");
}